package com.ruoyi.carShopService.mapper;

import java.util.List;
import com.ruoyi.carShopService.domain.CarUserBooking;
import org.apache.ibatis.annotations.Update;

/**
 * 维修预约Mapper接口
 * 
 * @author ruoyi
 * @date 2024-09-12
 */
public interface CarUserBookingMapper 
{
    /**
     * 查询维修预约
     * 
     * @param bookingId 维修预约主键
     * @return 维修预约
     */
    public CarUserBooking selectCarUserBookingByBookingId(Long bookingId);

    /**
     * 查询维修预约列表
     * 
     * @param carUserBooking 维修预约
     * @return 维修预约集合
     */
    public List<CarUserBooking> selectCarUserBookingList(CarUserBooking carUserBooking);

    //
    public List<CarUserBooking> selectCarUserBookingList2(CarUserBooking carUserBooking);



    //修改表中某一条数据的状态
    @Update("update car_user_booking set repair_status = #{repairStatus} where repair_order_no = #{repairOrderNo}")
    public int updateRepairStatus(CarUserBooking carUserBooking);

    /**
     * 新增维修预约
     * 
     * @param carUserBooking 维修预约
     * @return 结果
     */
    public int insertCarUserBooking(CarUserBooking carUserBooking);

    /**
     * 修改维修预约
     * 
     * @param carUserBooking 维修预约
     * @return 结果
     */
    public int updateCarUserBooking(CarUserBooking carUserBooking);


}
